<?php

/**
 * Controller Leiloes .
 * @package Controllers
 * @name Leilao_Controller
 * @category Site
 * @author carlos o carvalho <contato@carlosocarvalho.com.br>
 * @version 1.0.0
 * 
 * 
 */
class leiloes extends Public_Controller {

    private $taxas_admin;

    public function __construct() {
        parent::__construct();

        $this->load->library('User_Manager');

        $this->data ['printCatalogo'] = false;
        $this->data ['info_habilitacao'] = '';
        $this->data ['favoritos_user'] = array();
        if (userData()->id > 0) {
            $this->data ['favoritos_user'] = $this->Favoritos_M->all_info(array(
                        'USER_ID' => userData()->id
                    )) ? $this->Favoritos_M->all_info(array(
                        'USER_ID' => userData()->id
                    )) : array();
        }
    }
    /**
     * Closed Leilões
     * 
     * Exibição dos leilões realizados
     * 
     * @return view html
     */
    function closedLeiloes() {

        $this->data ['type_aba_active'] = 'CLOSED';
        $this->data ['estados_count'] = $this->Estados_M->get_count_lotes_closed();
        $this->data ['categories_count'] = $this->Categories_M->get_count_lotes_closed();
        $this->data ['sidebar'] = $this->load->view('frontend/public/sidebar', $this->data, true);
        $this->data ['data_leiloes'] = $this->Leilao_Model->get_leilao_closed();
       return $this->template(array(
            'frontend/public/home'
        ));
    }

}
